package cn.sh.yhk.acl.po;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;

import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * <p>
 *
 * </p>
 *
 * @author Yhk
 * @since 2024-10-06
 */
@Data
@TableName("sys_token_cache")
public class TokenCachePo implements Serializable {

    private static final long serialVersionUID = 1L;

    @TableId(value = "id", type = IdType.AUTO)
    private Long id;
    private String username;
    private String token;

    private LocalDateTime loginDate;

    private LocalDateTime notBeforeDate;

    private LocalDateTime expirationDate;

    private Integer refreshCount;

    private LocalDateTime maxExpirationDate;

    private LocalDateTime lastOperationDate;

    private String equipmentIp;


    @Override
    public String toString() {
        return "SysTokenCache{" +
                "id=" + id +
                ", token=" + token +
                ", loginDate=" + loginDate +
                ", notBeforeDate=" + notBeforeDate +
                ", expirationDate=" + expirationDate +
                ", refreshCount=" + refreshCount +
                ", maxExpirationDate=" + maxExpirationDate +
                ", oldOperationDate=" + lastOperationDate +
                ", equipmentIp=" + equipmentIp +
                "}";
    }

}
